//
//  AudioViewController.m
//  AriseSamePro
//
//  Created by 包日守 on 15/10/28.
//  Copyright © 2015年 Arise. All rights reserved.
//

#import "AudioViewController.h"
#import "ARAudioCell.h"

@interface AudioViewController ()

@end

@implementation AudioViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}
#pragma mark - Table view data source


- (CGFloat) tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath
{
    return 450;


}


- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
    ARAudioCell *cell = [tableView dequeueReusableCellWithIdentifier:@"ARAudioCell"];
    
    if (cell == nil) {
        
        
        [tableView registerNib:[UINib nibWithNibName:@"ARAudioCell" bundle:nil] forCellReuseIdentifier:@"ARAudioCell"];
        
        cell = [tableView dequeueReusableCellWithIdentifier:@"ARAudioCell"];
        
    }
    
    cell.cateModel = self.cateModels[indexPath.section];
    
    [cell setShareBtnBlock:^(ARCate5Model *cateModel, UIButton *sender) {
        [self createShare:cateModel WithSender:sender];
        
    }];
    
    return cell;

}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
